package com.xinxin.intelligenceexam.domain;

/**
 * User: xinxin
 * Date: 2016-10-30
 * Time: 11:49
 * FIXME
 */
public class Return {
    private int status;//1代表成功，0代表失败,2代表没有信息
    private int pageNum;//页码
    private String mesg;//信息
    private String data;

    public static Return commonReturn() {
        Return re = new Return();
        re.setStatus(1);
        return re;
    }

    public static Return faliReturn() {
        Return re = new Return();
        re.setStatus(0);
        re.setMesg("操作失败");
        return re;
    }

    public static Return successReturn() {
        Return re = new Return();
        re.setStatus(1);
        re.setMesg("操作成功");
        return re;
    }

    public int getPageNum() {
        return pageNum;
    }

    public Return setPageNum(int pageNum) {
        this.pageNum = pageNum;
        return this;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getMesg() {
        return mesg;
    }

    public void setMesg(String mesg) {
        this.mesg = mesg;
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }
}
